﻿CREATE TABLE [dbo].[ExpenseRequest] (
    [Id]                         UNIQUEIDENTIFIER ROWGUIDCOL NOT NULL,
    [RefNumber]                  NVARCHAR (50)    NOT NULL,
    [RequestDate]                DATE             NOT NULL,
    [ClaimBy]                    UNIQUEIDENTIFIER NULL,
    [TotalValue]                 MONEY            NULL,
    [ExpenseCurrencyId]          UNIQUEIDENTIFIER NULL,
    [CurrencyConvertedTo]        UNIQUEIDENTIFIER NULL,
    [ExchangeRateId]             UNIQUEIDENTIFIER NULL,
    [Remarks]                    NTEXT            NULL,
    [MBCurrency]                 UNIQUEIDENTIFIER NULL,
    [MBTotal]                    MONEY            NULL,
    [PreparedBy]                 UNIQUEIDENTIFIER NOT NULL,
    [ReviewedBy]                 UNIQUEIDENTIFIER NULL,
    [AuthorizedBy]               UNIQUEIDENTIFIER NULL,
    [CountryProgrammeId]         UNIQUEIDENTIFIER NULL,
    [PreparedOn]                 DATETIME         NULL,
    [ReviewedOn]                 DATETIME         NULL,
    [AuthorizedOn]               DATETIME         NULL,
    [RejectReviewRemarks]        NVARCHAR (350)   NULL,
    [RejectAuthorizedRemarks]    NVARCHAR (250)   NULL,
    [IsReviewed]                 BIT              NULL,
    [IsAuthorized]               BIT              NULL,
    [SettlementPaidBy]           UNIQUEIDENTIFIER NULL,
    [SettlementReceivedBy]       UNIQUEIDENTIFIER NULL,
    [SetReceivedCurrencyId]      UNIQUEIDENTIFIER NULL,
    [SetReceivedAmount]          MONEY            NULL,
    [SetReceivedExRate]          UNIQUEIDENTIFIER NULL,
    [SetReceivedConvertedAmount] MONEY            NULL,
    [SetTotalCurrencyId]         UNIQUEIDENTIFIER NULL,
    [SetTotalExpAmount]          MONEY            NULL,
    [SetTotalExRate]             UNIQUEIDENTIFIER NULL,
    [SetTotalConvertedAmount]    MONEY            NULL,
    [BalanceDueCurrencyId]       UNIQUEIDENTIFIER NULL,
    [BalanceDueAmount]           MONEY            NULL,
    [BalanceDueExRate]           UNIQUEIDENTIFIER NULL,
    [BalanceDueConvertedAmount]  MONEY            NULL,
    [SetPaidCurrencyId]          UNIQUEIDENTIFIER NULL,
    [SetPaidAmount]              MONEY            NULL,
    [SetPaidExRate]              UNIQUEIDENTIFIER NULL,
    [SetPaidConvertedAmount]     MONEY            NULL
);

